﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Admin.Master" AutoEventWireup="true"
    CodeBehind="AdminOrders.aspx.cs" Inherits="EHTSaleManager.UIAdmin.AdminOrders" %>

<%@ Register Src="~/UIAdmin/Control/PaggingControl.ascx" TagName="PaggingControl"
    TagPrefix="EHT" %>

<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
<h1>
        <asp:Label ID="lbAdminOrder" runat="server" Text="Order Leder"></asp:Label>
    </h1>
    <table style="width: 100%; height: 50px;">
        <tr>
            <td>
                <asp:HyperLink ID="hlOrderAppending" NavigateUrl="~/UIAdmin/AdminOrders.aspx?OrderState=1"
                    runat="server">Order Føye</asp:HyperLink>
            </td>
            <td>
                <asp:HyperLink ID="hlOrderShipping" NavigateUrl="~/UIAdmin/AdminOrders.aspx?OrderState=2"
                    runat="server">Order Skipsfart</asp:HyperLink>
            </td>
            <td>
                <asp:HyperLink ID="hlOrderAll" NavigateUrl="~/UIAdmin/AdminOrders.aspx?OrderState=-1"
                    runat="server">Alle Order</asp:HyperLink>
            </td>
        </tr>
    </table>
    <asp:Repeater ID="rpOrders" runat="server">
        <HeaderTemplate>
            <table cellspacing="0" cellpadding="0" class="data-table">
                <thead>
                    <tr>
                    <th class="actions edit">
                            NO
                        </th>
                       <%-- <th class="actions edit">
                            Check
                        </th>--%>
                        <th class="actions edit">
                            Detalj
                        </th>
                        <th>
                            Kundens navn
                        </th>
                        <th>
                            Adresse
                        </th>
                        <th>
                            By
                        </th>
                        <th>
                            Region
                        </th>
                        <th>
                            Telefon
                        </th>
                        <th>
                           Opprettet dato
                        </th>
                        <th>
                          Krev dato
                        </th>
                        <th>
                            Totalt beløp
                        </th>
                    </tr>
                </thead>
                <tbody>
        </HeaderTemplate>
        <ItemTemplate>
            <tr>
            <td class="actions edit">
                    <%#Eval("IndexId")%>
                </td>
               <%-- <td class="actions edit">
                    <asp:CheckBox ID="ckCheck" Checked="false" runat="server" />
                </td>--%>
                <td class="actions edit">
                    <a href='AdminOrderDetail.aspx?OrderID=<%#Eval("OrderID")%>'>
                        <img alt="Edit" src="/Styles/Edit.png"></a>
                </td>
                <th>
                    <%#Eval("ReceivedName")%>
                </th>
                <td>
                    <%#Eval("ReceivedAddress")%>
                </td>
                <td>
                    <%#Eval("ReceivedCity")%>
                </td>
                <td>
                    <%#Eval("RegionName")%>
                </td>
                <td>
                    <%#Eval("ReceicedPhone")%>
                </td>
                <td>
                    <%#Eval("CreatedDate")%>
                </td>
                <td>
                  <%#Eval("RequireDate")%>
                </td>
                <td>
                    <%#Eval("TotalAmount")%>
                </td>
            </tr>
        </ItemTemplate>
        <FooterTemplate>
            </tbody> </table>
        </FooterTemplate>
    </asp:Repeater>
    <p>
        <EHT:PaggingControl ID="PaggingControl1" runat="server" PageURL="AdminOrders.aspx"
            PageSize="10" />
    </p>

    <p class="submitButton">
        <asp:Button ID="btnexport" runat="server" Text="Eksporter fil" 
            onclick="btnexport_Click" />
        &nbsp;&nbsp;
        <asp:Button ID="btnSave" runat="server" Text="Lagre" />
    </p>
</asp:Content>
